<%--
    Document   : index
    Created on : 22.5.2011, 12:24:02
    Author     : Andrej Kuročenko <kurochenko@gmail.com>
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<c:set var="jspFolder" value="/WEB-INF/jsp/"/>
<c:set var="context" value="${pageContext.request.contextPath}" />
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <link href="${pageContext.request.contextPath}/css/default.css" rel="stylesheet" type="text/css" />
        <script src="${pageContext.request.contextPath}/js/jquery-1.6.1.min.js" type="text/javascript"></script> 
        <script src="${pageContext.request.contextPath}/js/functions.js" type="text/javascript"></script> 
        <title>${title}</title>
    </head>
    <body>
        <div id="header">
            <h1>${title}</h1>
        </div>
        <div id="menu">
            <ul>
                <li>Action:</li>
                <li>[ <a href="${pageContext.request.contextPath}">Data visualization</a> ]</li>
                <li>[ <a href="${pageContext.request.contextPath}/upload">Upload new measured data</a> ]</li>
            </ul>
        </div>
            <c:if test="${not empty hint}">
                <div id="hint">
                    <p><b>Hint:</b> ${hint}</p>
                </div>
            </c:if>
            <c:if test="${not empty error}">
                <div id="error">
                    <p><b>ERROR OCCURED:</b> ${error}</p>
                </div>
            </c:if>
            <c:if test="${not empty message}">
                <div id="message">
                    <p>${message}</p>
                </div>
            </c:if>
        <div id="content">
            <c:if test="${not empty page}">
                <c:import url="${jspFolder}${page}.jsp" />
            </c:if>
        </div>
    </body>
</html>